]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
screenShield: Fix unlock animation
authorFlorian Müllner <fmuellner@gnome.org>
Fri, 21 Sep 2012 22:06:26 +0000 (00:06 +0200)
committerFlorian Müllner <fmuellner@gnome.org>
Sat, 22 Sep 2012 11:50:25 +0000 (13:50 +0200)
When unlocking succeeds, the transition back to the user session is
animated. However, commit 8cf9baa1 broke the transition by hiding the
actor before starting the animation.

https://bugzilla.gnome.org/show_bug.cgi?id=684591

js/ui/screenShield.js

index ff410c862a168afe43b5e31c7d21e1fd3da0054c..3a56d312ece091738b3a8ad29203b7fa1727e76d 100644 (file)
@@ -429,6 +429,7 @@ const ScreenShield = new Lang.Class({
         this._hasLockScreen = false;
         this._isGreeter = false;
         this._isActive = false;
+        this._inUnlockAnimation = false;
 
         this._lightbox = new Lightbox.Lightbox(Main.uiGroup,
                                                { inhibitEvents: true,
@@ -766,6 +767,7 @@ const ScreenShield = new Lang.Class({
     },
 
     _tweenUnlocked: function() {
+        this._inUnlockAnimation = true;
         this.unlock();
         Tweener.addTween(this._lockDialogGroup, {
             scale_x: 0,
@@ -778,6 +780,7 @@ const ScreenShield = new Lang.Class({
                     this._dialog = null;
                 }
                 this.actor.hide();
+                this._inUnlockAnimation = false;
             },
             onCompleteScope: this
         });
@@ -799,7 +802,8 @@ const ScreenShield = new Lang.Class({
             this._isModal = false;
         }
 
-        this.actor.hide();
+        if (!this._inUnlockAnimation)
+            this.actor.hide();
 
         if (Main.sessionMode.currentMode == 'lock-screen')
             Main.sessionMode.popMode('lock-screen');